home *** CD-ROM | disk | FTP | other *** search
/ CyberMycha 2005 May / CyberMycha 05-2005 (Poland).bin / Immortal / cotndemo.exe / Data1.cab / shadow.vsh < prev    next >
Encoding:
Text File  |  2004-11-16  |  534 b   |  15 lines

  1. vs_1_1                    // version
  2. dcl_position v0            // input vertex position
  3.  
  4. def c20,1,1,1,1            // want to not have any fog in shadow buffer
  5.  
  6. m4x4 r0,v0,c12            // transform v0 by matrix at c12 and store in r0
  7. mov oPos,r0                // output position
  8.  
  9. // mov oT0.x,r0.z        // no scaling (problem is that default color interferes)
  10. mul oT0.x,r0.z,c7.w        // scale z-value by constant in c7.x (1/maxz) 
  11.  
  12. mov oFog,c20.x            // set fog alpha to 1.0 - so we don't have to worry about fog color
  13.  
  14. // mad oT0.x,r0.z,c7.x,c7.z // add zbias at the same time
  15.